<template>
    <div class="container" v-if="show">
        <div class="loading"></div>
    </div>
</template>
<script>
  export default {
    name: "loading",
    data() {
      return {
        show: false
      }
    }
  }
</script>
<style scoped>
.container {
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  z-index: 9999;
}

/* .container::before{content: '';position: fixed;left: 0;right: 0;top: 0;bottom: 0;background: rgba(0,0,0,.5);} */

.loading {
  width: 100px;
  height: 100px;
  margin: 0 auto;
  border-radius: 100%;
  border: 5px #ffffff solid;
  border-right-color: #87CEEB;
  animation: loading 1s linear infinite;
}

@keyframes loading {
  0% {
    transform: rotate(0deg);
  }
  100% {
    transform: rotate(360deg);
  }
}
</style>